package com.example.backend.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.backend.pojo.Borrow;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Map;

@Mapper
public interface BorrowMapper extends BaseMapper<Borrow> {
    @Select("select * from borrow,book where book.bid=borrow.bid")
    List<Map<String, Object>> selectBooksWithBorrowAndBookName();
}
